package beastick.utility;

public class PlaceholderProcessor extends CStringParameterizer
{
 private String S_PLACEHOLDER_BEGIN = "[%%";
 private String S_PLACEHOLDER_END   = "%%]";

 public void setPlaceholderBraces(String sPlaceholderBegin,
   String sPlaceholderEnd)
 {
  S_PLACEHOLDER_BEGIN = sPlaceholderBegin;
  S_PLACEHOLDER_END = sPlaceholderEnd;
 }

 public String getPlaceholderBegin()
 {
  return S_PLACEHOLDER_BEGIN;
 }

 public String getPlaceholderEnd()
 {
  return S_PLACEHOLDER_END;
 }

 public void ProcessPlaceholder(String sName, String sValue)
 {
  Replace(S_PLACEHOLDER_BEGIN + sName.trim() + S_PLACEHOLDER_END, sValue);
 }

 public void cleanPlaceholder()
 {
  UnknownCompiled(S_PLACEHOLDER_BEGIN, S_PLACEHOLDER_END);
 }

}
